from aiogram import Dispatcher, types
from aiogram.filters import Text
from aiogram_dialog import DialogManager, StartMode

from app.bot.states.user import LinksState


async def links_list(message: types.Message, dialog_manager: DialogManager):
    await dialog_manager.start(
        LinksState.links_list, mode=StartMode.RESET_STACK
    )


def register_links_handlers(dispatcher: Dispatcher):
    dispatcher.message.register(links_list, Text(text="Список товаров"))
